package com.fakeDYChat.common.common.exception;

import lombok.AllArgsConstructor;

@AllArgsConstructor
public enum CommonErrorEnum implements ErrorEnum {
    //{0}便于后续替换
    BUSINESS_ERROR(0, "{0}"),

    SYSTEM_ERROR(-1, "系统出小差了，请稍后再试"),

    PARAM_INVALID(-2, "参数校验错误"),
    LOCK_LIMIT(-3, "请求太频繁了，请稍后再试哦~~");

    private final Integer code;
    private final String msg;

    @Override
    public java.lang.Integer getErrorCode() {
        return code;
    }

    @Override
    public String getErrorMsg() {
        return msg;
    }
}
